package com.zaimokuza.cn.entity.blog;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import javax.validation.constraints.NotBlank;
import java.util.ArrayList;

/**
 * @author zaimokuza
 */
@ApiModel("博客评论")
@Data
public class Comment {

    @ApiModelProperty("评论ID")
    private String id;
    @ApiModelProperty("博客ID")
    private String blogId;
    @ApiModelProperty("博客名称")
    private String blogName;
    @ApiModelProperty("用户ID")
    private String userId;
    @ApiModelProperty("展示字段，用户名称")
    private String userName;
    @ApiModelProperty("展示字段，用户域名")
    private String userDomain;
    @ApiModelProperty("展示字段，用户头像")
    private String userAvatar;
    @ApiModelProperty("评论内容")
    @NotBlank(message = "请填写评论内容！")
    private String content;
    @ApiModelProperty("父评论ID")
    private String parentId;
    @ApiModelProperty("@用户ID")
    private String atUserId;
    @ApiModelProperty("展示字段，@用户名称")
    private String atUserName;
    @ApiModelProperty("展示字段，@用户域名")
    private String atUserDomain;
    @ApiModelProperty("展示字段，@用户头像")
    private String atUserAvatar;
    @ApiModelProperty("点赞数")
    private Integer likes;
    @ApiModelProperty("是否点赞")
    private Boolean isLike;
    @ApiModelProperty("创建时间")
    private String createdTime;
    @ApiModelProperty("展示字段，子评论集合")
    private ArrayList<Comment> childList;

}
